#include "dbshow.h"
#include "ui_dbshow.h"
#include "login.h"

dbshow::dbshow(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::dbshow)
{
    ui->setupUi(this);
    connect(ui->pushButton, &QPushButton::clicked, [=]() {
        ui->stackedWidget->setCurrentIndex(1);
    });

    connect(ui->pushButton_2, &QPushButton::clicked, [=]() {
        ui->stackedWidget->setCurrentIndex(2);
    });


    QWidget *p_login = new login;
    qDebug() << ui->stackedWidget->addWidget(p_login);
    QWidget *p_login2 = new login;
    qDebug() << ui->stackedWidget->addWidget(p_login2);
}

dbshow::~dbshow()
{
    delete ui;
}
